home *** CD-ROM | disk | FTP | other *** search
/ Headbone Interactive / Headbone_Interactive_CD-ROM_Sampler_1995.iso / pc / demos / pants / intro.dxr / 00104_misc scripts.ls < prev    next >
Encoding:
Text File  |  1995-09-15  |  1.0 KB  |  38 lines

  1. on idleAnimation
  2.   global gvLocaleList, gvCharList, gvCharTalks, SFX_EXT, gAnimLoopTime
  3.   set the mouseDownScript to "handleMouseDown"
  4.   cursor(0)
  5.   set vTime to the timer - gAnimLoopTime
  6.   if (vTime >= 600) and (vTime <= 700) and not soundBusy(1) then
  7.     set vChar to random(count(gvCharList))
  8.     go(string(getAt(gvCharList, vChar)) && "idle")
  9.   else
  10.     if vTime > 1300 then
  11.       set vChar to random(count(gvCharList))
  12.       set gvCharTalks to string(getAt(gvCharList, vChar)) && "Talks"
  13.       set gAnimLoopTime to the timer
  14.       puppetSound(vChar & "Intro1" & SFX_EXT)
  15.       updateStage()
  16.       go(gvCharTalks)
  17.     else
  18.       set vWhichLocale to random(count(gvLocaleList))
  19.       go(getAt(gvLocaleList, vWhichLocale))
  20.     end if
  21.   end if
  22. end
  23.  
  24. on waitSound vChannel
  25.   repeat while soundBusy(vChannel)
  26.     nothing()
  27.   end repeat
  28. end
  29.  
  30. on GoMain
  31.   global gvTrack, gvCurLetter, gCDPATH, SFX_EXT
  32.   set gvCurLetter to "B"
  33.   puppetSound(0)
  34.   puppetSound(1, the number of cast "B.aif")
  35.   updateStage()
  36.   go("B1", gCDPATH & "Main")
  37. end
  38.